package com.module.guide.ui.activity;

import android.content.Context;
import android.content.Intent;

import com.module.guide.R;
import com.module.guide.base.BaseActivity;
import com.module.guide.utils.CfgUtils;

public class AppStartActivity extends BaseActivity {
    @Override
    protected void initView() {
        super.initView();
        startActivity();

    }

    @Override
    protected int getLayoutResId() {
        return R.layout.activity_app_start;
    }
    private void startActivity()
    {
        if(CfgUtils.findByKeyBool("isFirstStart",true, getBaseContext()))
        {
            startActivity(new Intent(getBaseContext(),GuideActivity.class));
            CfgUtils.insertByKey("isFirstStart",false,getBaseContext());
        }else {

            startActivity(new Intent(getBaseContext(),MainActivity.class));
        }
        finish();
    }
}
